import { RouteRecordRaw } from 'vue-router'
import { ROUTER_NAME } from '@/constant'
import { LAYOUT, BLANK_LAYOUT } from '@/router/constant'
import { setRootPathByPermission } from '@/router/util'

const pageRouterConfig: RouteRecordRaw = {
    name: ROUTER_NAME.PAGE_DASHBOARD + '_ROOT',
    // 匹配全部其他内容
    path: import.meta.env.VITE_PUBLIC_PATH + '/',
    redirect: () => {
        return setRootPathByPermission()
    },
    component: LAYOUT,
    meta: {
        isLayout: true,
        hideMenu: false,
        title: 'MENU_LAYOUT'
    },
    children: [
        {
            name: 'menu_page_50000005_or1v6r878w',
            path: '/menu_50000005_or1v6r878w',
            redirect: '/app_50000005/page/50000513',
            meta: {
                code: '50000005_or1v6r878w',
                settingId: 'null',
                menuExpandFlag: true,
                hideMenu: false,
                title: '项目管理',
                icon: ''
            },
            children: [
                {
                    path: '/app_50000005/page/jiaofu',
                    component: () => import('@/views/page/jiaofu.vue'),
                    meta: {
                        code: '50000005_odurqo1bxv',
                        settingId: '50000503',
                        menuExpandFlag: true,
                        hideMenu: false,
                        title: '检查清单管理',
                        icon: 'null'
                    }
                }
            ]
        },

        {
            name: 'menu_page_50000005_r1b0l7hmae',
            path: '/menu_50000005_r1b0l7hmae',
            redirect: '/app_50000005/allin-app/allin-privilege-management-web/organizational',
            meta: {
                code: '50000005_r1b0l7hmae',
                settingId: 'null',
                menuExpandFlag: true,
                hideMenu: false,
                title: '系统管理',
                icon: ''
            },
            children: [
                {
                    name: 'menu_system_f7f3cf7e-d470',
                    path: '/app_50000005/allin-app/allin-privilege-management-web/organizational',
                    component: () => import('@/views/system/MicroAppViteContainer.vue'),
                    meta: {
                        code: 'lowCode_organizational',
                        settingId: 'f7f3cf7e-d470',
                        menuExpandFlag: true,
                        hideMenu: false,
                        title: '组织架构管理',
                        icon: 'null'
                    }
                },
                {
                    name: 'menu_system_f3b6d861-1a04',
                    path: '/app_50000005/allin-app/allin-privilege-management-web/user_group',
                    component: () => import('@/views/system/MicroAppViteContainer.vue'),
                    meta: {
                        code: 'lowCode_userGroup',
                        settingId: 'f3b6d861-1a04',
                        menuExpandFlag: true,
                        hideMenu: false,
                        title: '用户组管理',
                        icon: 'null'
                    }
                },
                {
                    name: 'menu_system_6ff38628-3b17',
                    path: '/app_50000005/allin-app/allin-privilege-management-web/role',
                    component: () => import('@/views/system/MicroAppViteContainer.vue'),
                    meta: {
                        code: 'lowCode_role',
                        settingId: '6ff38628-3b17',
                        menuExpandFlag: true,
                        hideMenu: false,
                        title: '角色管理',
                        icon: 'null'
                    }
                },
                {
                    name: 'menu_system_d55db19a-639f',
                    path: '/app_50000005/allin-app/allin-privilege-management-web/user',
                    component: () => import('@/views/system/MicroAppViteContainer.vue'),
                    meta: {
                        code: 'lowCode_user',
                        settingId: 'd55db19a-639f',
                        menuExpandFlag: true,
                        hideMenu: false,
                        title: '用户管理',
                        icon: 'null'
                    }
                },
                {
                    path: '/app_50000005/page/50000520',
                    component: () => import('@/views/page/Page50000520.vue')
                },
                {
                    path: '/app_50000005/page/shichang',
                    component: () => import('@/views/page/shichang.vue')
                },
                {
                    path: '/app_50000005/page/jixiao',
                    component: () => import('@/views/page/jixiao.vue')
                },
                {
                    path: '/app_50000005/page/pingtai',
                    component: () => import('@/views/page/pingtai.vue')
                },
                {
                    path: '/app_50000005/page/hetong',
                    component: () => import('@/views/page/contractManagement.vue')
                },
                {
                    path: '/app_50000005/page/ceshi',
                    component: () => import('@/views/page/ceshi.vue')
                },
                {
                    path: '/app_50000005/page/kanban',
                    component: () => import('@/views/page/kanban.vue')
                },
                {
                    path: '/app_50000005/page/mubiao',
                    component: () => import('@/views/page/mubiao.vue')
                },
                {
                    path: '/app_50000005/wubian/xinqianhetong',
                    component: () => import('@/views/wubian/xinqianhetong.vue')
                },
                {
                    path: '/app_50000005/wubian/shengchanjiaofu',
                    component: () => import('@/views/wubian/shengchanjiaofu.vue')
                },

                {
                    path: '/app_50000005/wubian/churuku',
                    component: () => import('@/views/wubian/churuku.vue')
                },
                {
                    path: '/app_50000005/wubian/fahuo',
                    component: () => import('@/views/wubian/fahuo.vue')
                },
                {
                    path: '/app_50000005/wubian/huikuan',
                    component: () => import('@/views/wubian/huikuan.vue')
                },
                {
                    path: '/app_50000005/wubian/yikaipiao',
                    component: () => import('@/views/wubian/yikaipiao.vue')
                },
                {
                    path: '/app_50000005/wubian/dangjin',
                    component: () => import('@/views/wubian/dangjin.vue')
                },
                {
                    path: '/app_50000005/wubian/kucun',
                    component: () => import('@/views/wubian/kucun.vue')
                },
                {
                    path: '/app_50000005/crm/xiansuo',
                    component: () => import('@/views/crm/xiansuo.vue')
                },
                {
                    path: '/app_50000005/crm/guanjian',
                    component: () => import('@/views/crm/guanjian.vue')
                },
                {
                    path: '/app_50000005/crm/table',
                    component: () => import('@/views/crm/table.vue')
                },
                {
                    path: '/app_50000005/crm/ceshi',
                    component: () => import('@/views/crm/ceshi.vue')
                },
            ]
        }
    ]
}
export default pageRouterConfig
